//
//  PTCallRecording.swift
//  PointTest28
//
//  Created by sc-chen on 2023/6/26.
//

import SwiftUI

struct PTCallRecording: View {
    
    @State private var isShowingHUD = false
    @State private var detailTxt = "不支持通话录音功能"
    
    var body: some View {
        /*ZStack {
            VStack {
                Button {
                    showHud()
                } label: {
                    Text("通话录音功能")
                        .frame(maxWidth: .infinity,maxHeight: 40)
                        .foregroundColor(.blue)
                        .overlay(
                            RoundedRectangle(cornerRadius: 10)
                                .stroke(Color.blue, lineWidth: 1)
                        )
                }
                .buttonStyle(.plain)
                .padding()
                Spacer()
            }
            PTProgressHud(isPresented: $isShowingHUD, text: $detailTxt)
            
        }.onAppear(){
            showHud()
        }*/
        
        Text("不支持通话录音的开发功能")
    }
    
    private func showHud() {
        isShowingHUD = true
        DispatchQueue.main.asyncAfter(deadline: .now()+2){
            isShowingHUD = false
        }
    }
}

struct PTCallRecording_Previews: PreviewProvider {
    static var previews: some View {
        PTCallRecording()
    }
}
